The tie/slur problem

While typesetting notes and even beams is a rather simple problem because is is a local typesetting, ties and slurs are much more difficult to handle.

Or course there is little problem in case of a typesetter wanting a slur or a tie binding two consecutive notes, not separated by a bar. In practice this very restricted use of slurs or ties can easily be solved by putting some symbols extracted from the slur16 or slurn16/slurn20 fonts somewhere on the staffs using the general use \zcharnote macro.

But serious music typesetters or composers know that many ties are supposed to link notes which are on both sides of a bar, which is a likely place to insert line breakings, so that the tie coding must have various versions and sizes to resist that possible line breaking. What has been said about ties is still more serious in the case of phrasing slurs which may extend over several bars, lines and sometimes pages. In this case, their shape is not only a question of producing a long curved symbol of nice looking shape, it also has to cope with glue. An then the worst is that music way of typing does not accept ragged lines but equal length lines, even for the last line of a music piece. Thus, long distance slurs and ties need to be cut into separate parts (beginning, continuing(s), endings) which TEX can only link using horizontal line overlaps or \leaders to insure slur continuity over this unavoidable glue.

Therefore and up to now, ties and slurs have been implemented in a way which may look rather ugly, but we think it is the only way of implementing in one pass ties and slurs which run across glue. The principle is to have tie/slur symbols with a rather long part of horizontal stuff. Then, at each time a glue occurs and at each time a group of notes is coded while a slur or tie is pending, an \hrule is issued which overlaps the preceeding tie/slur symbol so that the final output seems to contain a continuous line. Unfortunately, this is possible only in the glue expansion direction, namely in the horizontal direction.

It could be requested – and this is thought of – to have variable size initial and final curved slur symbols which the user would choose according to his intention to have short or long range slur symbols. This has not been yet implemented for several reasons :